<?php
  header("Content-type: text/plain; charset=utf-8");
  header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT");
  header("Cache-Control: no-store, no-cache, must-revalidate");
  header("Cache-Control: post-check=0, pre-check=0", false);
  header("Pragma: no-cache");

	if (isset($_REQUEST["i"])) {
    $id=explode(' ',$_REQUEST["i"]);
    mb_internal_encoding('UTF-8');
    $connection=mysql_connect("127.0.0.1","avtovokzal","pipzemkam") or die("Ошибка соединения с сервером");
    $db=mysql_select_db("avtovokzal",$connection) or die("Ошибка при выборе базы данных");
    @mysql_query('set character_set_client="utf8"');
    @mysql_query('set character_set_results="utf8"');
    @mysql_query('set collation_connection="utf8_general_ci"');
    $row=mysql_fetch_array(mysql_query("SELECT * FROM `info` WHERE `id`='".$id[0]."'"));
    echo $row["title"].'|'.$row["text"];
    mysql_close($connection);    
  }

?>